package global

import (
	"sync"
	"time"
)

var HeaderConf = []Header{
	{"名称", 120},
	{"主机名", 200},
	{"IP", 180},
	{"成功次数", 100},
	{"失败次数", 100},
	{"失败比例", 100},
	{"最后一次Ping状态", 200},
	{"最后一次Ping用时", 200},
	{"平均一次Ping用时", 200},
	{"最长Ping用时", 180},
	{"最短Ping用时", 180},
}

// PingInterval PING测试间隔，单位：秒
var PingInterval = 10 * time.Second

// TimesPerInterval 每个测试间隔内测试次数
var TimesPerInterval = 10

// PingTimeout PING测试超时时间，单位：秒
var PingTimeout = 2 * time.Second

var ProtocolICMP = 1

var PingData = "abcdefghijklmnopqrstuvwxyzabcdefghijkl" // 提取数据为常量，增强可读性

var Services []ServiceConfig

var PingWg = sync.WaitGroup{}

type Header struct {
	Name   string
	Length float32
}

type ServiceConfig struct {
	Name string
	Host string
}
